# Title: Blank Log Generator
# 
# Description: Simple script for automatically generating logs. Each log will be generated with a creation and last modified date of the current date -1 day for
#              each log created.
# 
# 
# Created by: Eric (eric[at]fizi.ca)
# Version: 1.0
# Created date: Sept. 22nd, 2008

$logsToCreate = "" #Full directory path to create the logs in
$totalLogsCreated = 30 #How many logs to create

#Loop for creating $totalLogsCreated worth of logs
for ($i = 0; $i -le $totalLogsCreated; $i++) {

	fsutil file createNew $logsToCreate\sampleLogFile$i.log 1000 #Creates a 1kb empty file
	set-itemproperty $logsToCreate\sampleLogFile$i.log CreationTime (Get-Date).AddDays(-$i) #Sets the creation date of the file to the current date - $i days
	set-itemproperty $logsToCreate\sampleLogFile$i.log LastWriteTime (Get-Date).AddDays(-$i) #Sets the last modified time of the file to the current date -$i days

}